package org.example.spring_book.model;

import lombok.Data;

/**
 * @ClassName PageRequest
 * @Description TODO
 * @Author wangxiaodong
 */
@Data
public class PageRequest {
    private Integer currentPage = 1; // 当前⻚
    private Integer pageSize = 10; // 每⻚中的记录数
    private Integer offset;
    public Integer getOffset() {
        return (currentPage - 1) * pageSize;
    }
}